import 'dart:async';

import 'package:check_app/api/request.dart';
import 'package:check_app/model/upload.dart';

const PATH = '/storage/create';
const LIST_PATH = '/storage/create/multiple';

///首页接口
class UploadDao {
  static Future upload(params) async {
    final response = await Request().upload(PATH, queryParameters: params);
    return UploadResult.fromJson(response);
  }

  static Future uploadList(params) async {
    final response = await Request().upload(LIST_PATH, queryParameters: params);
    return UploadListResult.fromJson(response);
  }
}
